﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ChangePassword.aspx.cs" Inherits="admin_ChangePassword" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>无标题页</title>
     <link rel="Stylesheet" type="text/css" href="../Styles/right_style.css" />
   <script type="text/javascript" src="../Scripts/jquery.ui/js/jquery.js"></script>

   <style type="text/css">
<!--
html{ scrollbar-base-color: #dbecf8; scrollbar-arrow-color: #2a8ed1; scrollbar-track-color: #bdddf2; scrollbar-3dlight-color: #2886c5; scrollbar-darkshadow-color: #2886c5;
scrollbar-face-color: #dbecf8; scrollbar-shadow-color: #dbecf8;  }
-->
</style>
</head>
<body>
    <form id="form1" runat="server">

         <!--修改密码-->
    <div id="tb1_3_content" class="cont01_word">
      <div class="person_ziliao">
         <div class="person_xinxi_title" align="left">修改密码</div>        
         <div class="person_xinxi_neirong" align="left">
           <div class="person_neirong_list">用 户 名：&nbsp;&nbsp;<span class="mima_user_ming"><asp:Label ID="lblLoginName" runat="server"></asp:Label></span></div>
           <div class="person_neirong_list">原 密 码：&nbsp;&nbsp;
             <asp:TextBox ID="txtPassword" runat="server" TextMode="Password"></asp:TextBox>
           </div>
           <div class="person_neirong_list">新 密 码：&nbsp;&nbsp;
             <asp:TextBox ID="txtNewPassword" runat="server" TextMode="Password"></asp:TextBox>
             <span>6-20位</span>
           </div>
           <div class="person_neirong_list">确认新密码：
             <asp:TextBox ID="txtReNewPassword" runat="server" TextMode="Password"></asp:TextBox>
             <span>6-20位</span>
           </div>
         </div>
         <div class="person_ziliao_save" align="left">
            <asp:Button ID="btnSave" runat="server" OnClick="btnSave_Click" Text="" CssClass="save_bg" OnClientClick="return checkfrm()"/>
         </div>
       </div>
    </div>
    </form>
</body>
</html>
<script type="text/javascript" language="javascript">
    function checkfrm()
    {
        if(document.getElementById('txtPassword').value == '')
        {
            alert('原密码不能为空！');
            return false;
        }
        if(document.getElementById('txtNewPassword').value == '')
        {
            alert('新密码不能为空！');
            return false;
        } 
        if(document.getElementById('txtReNewPassword').value == '')
        {
            alert('确认新密码不能为空！');
            return false;
        } 
        if(document.getElementById('txtNewPassword').value.length < 6 || document.getElementById('txtNewPassword').value.length >20)
        {
            alert('新密码长度不正确！(大于6或小于20个字符)');
            return false;
        }
        if(document.getElementById('txtNewPassword').value != document.getElementById('txtReNewPassword').value)
        {
            alert('新密码和确认密码必须相同！');
            return false;
        }  
        return true;
    }
</script>
